//
//  SHPayManager.h
//  SHWeChatAliPay
//
//  Created by 索晓晓 on 2021/10/26.
//

#import <Foundation/Foundation.h>

#define kQQAppID @""
#define kQQAppSecret @""
//
///// QQ登录成功通知
//#define SHWXLoginSuccessNotification @"SHWXLoginSuccessNotification"
///// QQ登录失败通知
//#define SHWXLoginFailNotification @"SHWXLoginFailNotification"
///// QQ分享通知
//#define SHWXShareResultNotification @"SHWXShareResultNotification"

NS_ASSUME_NONNULL_BEGIN

/// <#Description#>
@interface SHQQManager : NSObject

+ (instancetype)sharedInstance;

+ (void)regisAppId:(NSString *)appid andUniversalLink:(NSString *)link;

/**
 @brief 处理微信url, 如果wechatSDK不能处理该url，则返回false
 @param url url
 @return 微信能处理, 返回true, 否则返回false
 */
+ (BOOL)openURL:(NSURL*)url;
/**
 * (静态方法)处理应用的UniversalLink拉起协议
 * \param url 处理被其他应用呼起时的逻辑
 * \return 处理结果，YES表示成功，NO表示失败
 */
+ (BOOL)HandleUniversalLink:(NSURL *)url;

/// 登录
+ (void)doLogin:(void(^)(NSDictionary *result))complate;

/// 获取用户信息
+ (void)getQQUserInfo:(void(^)(NSDictionary *result))complate;

/// 分享新闻到QQ
/// @param title 标题
/// @param description 描述
/// @param imageData 图片
/// @param linkUrl 跳转链接地址
/// @param qzone 是否空间
+ (void)shareNewsTitle:(NSString *)title
               content:(NSString *)description
       reviewImageData:(NSData *)imageData
               jumpUrl:(NSString *)linkUrl
                 qzone:(BOOL)qzone;


/// 分享纯图片到QQ
/// @param imageData 图片二进制数据
/// @param title 标题
/// @param description 描述
+ (void)shareImgae:(NSData *)imageData
             title:(NSString *)title
           content:(NSString *)description;


/// 分享纯文本到QQ
/// @param title 标题
+ (void)shareTitle:(NSString *)title;

@end

NS_ASSUME_NONNULL_END
